{% load bootstrap_tags %}

<form method="POST" action="{% url profile_edit %}">
    <fieldset>
        {% csrf_token %}
        {{ profile_form|as_bootstrap }}
        <div class="form-actions">
            <button type="submit" class="btn btn-primary">Update</button>
            <a href="{% url profile_detail profile.user.username %}" class="btn">Cancel</a>
        </div>
    </fieldset>
</form>